Field of the Invention
The present invention relates to an image pickup apparatus, such as a digital single-lens reflex camera and a digital video camera, and a method of controlling the image pickup apparatus, and to a storage medium, and more particularly, to an operational control technique at the time of shooting a moving image.
Description of the Related Art
In recent years, CMOS image sensors (hereafter, referred to as “CMOS sensors”) have come into widespread use as image pickup elements for image pickup apparatuses, notably video cameras. Most of the CMOS sensors adopt a rolling shutter system, which consecutively performs exposures for horizontal lines, and reads a moving image signal for each line to create one frame.
In the CMOS sensor having the rolling shutter system, a difference arises between an exposure timing and a reading time for each line. Therefore, if an external flash such as strobe light having a short light-emission time is applied to a subject in shooting, an image may be generated which is divided into upper and lower portions having different brightness. Such an effect to a frame where a band-like gap in brightness occurs due to such external flash is called a “flash band effect”, and various techniques to compensate for the band-like gap in brightness have been proposed.
For example, Japanese Laid-Open Patent Publication (Kokai) No. 2012-156634 discloses a detecting method and a compensating method for the flash band effect. In Japanese Laid-Open Patent Publication (Kokai) No. 2012-156634, brightness levels are compared between consecutive frames for each pixel, a horizontal line having a great amount of variation in the brightness level is identified from the comparison result and a boundary between the horizontal line having the great amount of variation and a horizontal line having a small amount of variation is detected to detect the occurrence of the flash band effect. In addition, in Japanese Laid-Open Patent Publication (Kokai) No. 2012-156634, brightness values of a pixel contained in consecutive frames are compared and the pixel is replaced with the pixel having a greater brightness value, with the pixel having a smaller brightness value, or with the pixel having the average of the brightness values, to output a compensated frame with no band-like gap in brightness.
As seen above, typical methods for compensating for the band-like gap in brightness include a method of comparing the brightness of two or more frames having the band-like gap in brightness occurring and performing an image combining process based on the comparison result.
In the case where the shutter speed of the image pickup element (equal to an exposure period (an accumulating time of electric charge being a signal) in a CMOS sensor) is shorter than a frame rate (a vertical synchronizing signal input into the image pickup element) at which the image pickup element is driven, a band-like high brightness area occurs only in a part of a frame. In this case, in the above Japanese Laid-Open Patent Publication (Kokai) No. 2012-156634, a flash-eliminated image is output where a pixel having a high brightness value in a frame in which a band-like gap in brightness occurs is replaced with a pixel having a low brightness value in the next frame. In such a method, it is difficult to combine a full flash image if the band-like high brightness area occurs only in a part of one frame.
Therefore, to obtain a full flash image using the technique disclosed in the above Japanese Laid-Open Patent Publication (Kokai) No. 2012-156634, a shutter speed in a mode for performing the compensation of the band-like gap in brightness needs to have the same length as the frame rate of the image pickup apparatus. For this reason, a user of the image pickup apparatus cannot optionally change a shutter speed when selecting an action to compensate the band-like gap in brightness.